package com.demo.pattern.decorate;

/**
 * @author sourire
 * @version 1.0
 * @date 2020/8/27 10:31
 */
public class Client {
    public static void main(String[] args) {
        Beverage darkRoast = new DarkRoast();
        Beverage Milk = new Milk(darkRoast);
        System.out.println(Milk.getDescribe()+Milk.cost());
        System.out.println("==========");
        Beverage Milk2 = new Milk(Milk);
        System.out.println(Milk2.getDescribe()+Milk2.cost());

        Beverage decaf = new Decaf();
        Beverage whip = new Whip(decaf);
        System.out.println(whip.getDescribe()+whip.cost());

    }
}
